1. Field of the Invention
The present invention relates to a program control method and program control apparatus for controlling parallel execution of commands (instructions) in a microprocessor.
2. Description of the Prior Art
Program control devices which repeatedly execute already fetched commands as a means of achieving high speed program execution or reducing the number of words in the command memory are known in the prior art.
These devices typically provide in hardware a repeat counter for counting the number of times a single command is repeated, and a repeat counter set command in the command set. The command to be repeatedly executed is placed in the command memory immediately after the repeat counter set command. The number of repetitions for the repeated command is set in the repeat counter by executing the repeat counter set command. The repeat counter is counted down each time the repeated command is executed, and the command following the repeat counter set command (i.e., the command to be repeated) is then repeatedly executed until the value of the repeat counter becomes zero.
In a digital signal processor (DSP) designed for high speed computation, there are often cases in which a limited data set can be processed parallel to the repeated execution of a specific operating command (e.g., a multiply-and-accumulation command). However, parallel processing is not possible with conventional program control devices, and such program control devices are therefore not suited as a command controller for high speed DSP devices.